import doc from '@img/file/doc.png'
import pdf from '@img/file/pdf.png'
import xls from '@img/file/xlsx.png'
import text from '@img/file/text.png'
import png from '@img/file/PNG.png'
import { getFileType } from './index.js'


export const getFileIcon = (fileName) => {
    const type = getFileType(fileName);
    switch (type) {
        case 'xlsx':
            return xls;
        case 'doc':
            return doc;
        case 'pdf':
            return pdf;
        case 'text':
            return text;
        case 'png':
            return png;
        default:
            return doc;
    }
}